<?php

declare(strict_types=1);

/**
 * @Author:     Frank
 * @contact     frank_hhm@163.com
 * @Date:       2022-12-08 17:01:26
 * @Last Modified time: 2022-12-08 17:21:07
 */
namespace app\common\enum\store\shipping;

use frank\base\BaseEnum;

/**
 * 枚举类
 * Class TypeEnum
 * @package app\common\enum\store\shipping
 */
class TypeEnum extends BaseEnum
{
    const PIECE = 1;

    const WEIGHT = 2;

    const VOLUME = 3;

    /**
     * 获取枚举数据
     * @return array
     */
    public static function data()
    {
        return [
            self::PIECE => [
                'name' => '按件',
                'unit' => '',
                'value' => self::PIECE,
            ],
            self::WEIGHT => [
                'name' => '按重量',
                'unit' => '重量(kg)',
                'value' => self::WEIGHT,
            ],
            self::VOLUME => [
                'name' => '按体积',
                'unit' => '体积(m³)',
                'value' => self::VOLUME,
            ],
        ];
    }
}